<template>
  <div>
    <fieldset>
      <legend>child2</legend>
      <h1>child2</h1>
      <button @click="send2">点击传递</button>
    </fieldset>
  </div>
</template>
<style scoped>
h1 {
  color: hotpink;
}
</style>
<script>
export default {
  data() {
    return {
      k: "海豚吃桃子",
    };
  },
  methods: {
    send2() {
      this.$bus.$emit("get2", this.k);
    },
  },
};
</script>
